package com.linhai.scm.service.impl;

import java.io.Serializable;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import com.linhai.scm.dao.IUserDao;
import com.linhai.scm.entity.base.User;
import com.linhai.scm.service.IUserService;

//@Service("UserService")
@Service
public class UserService extends BaseService<User> implements IUserService{
	
	@Autowired
	private IUserDao userDao; 
	
	/**
	 * 用户登录验证
	 * @param user 需要验证的用户实体
	 * @return 验证成功为true，验证不成功为false
	 */
	public boolean auth(User user){
		return userDao.auth(user);
	}
	
	public Serializable insert(User user){
		if(user!=null){
			return userDao.insert(user);
		}
		return null;
	}
}
